import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';

/// 显示地块流转类型 dialog
Future<String?> showLandFlowTypeDialog({required BuildContext context}) {
  return showDialog(
    context: context,
    builder: (context) {
      return const LandFlowTypeDialog();
    },
  );
}

class LandFlowTypeDialog extends StatelessWidget {
  const LandFlowTypeDialog({super.key});

  @override
  Widget build(BuildContext context) {
    return Center(
      child: Container(
        width: double.infinity,
        margin: EdgeInsets.symmetric(vertical: 10.w, horizontal: 32.w),
        padding: EdgeInsets.only(left: 15.w, right: 15.w, top: 15.w),
        decoration: BoxDecoration(
            color: Colors.white, borderRadius: BorderRadius.circular(10.w)),
        child: Column(
          mainAxisSize: MainAxisSize.min,
          children: [
            Text(
              '请选择',
              style: TextStyle(color: const Color(0xFF333333), fontSize: 16.sp),
            ),
            SizedBox(
              height: 10.w,
            ),
            Container(
              height: 1.w,
              color: const Color(0xFFECECEC),
            ),
            GestureDetector(
              onTap: () {
                Navigator.of(context).pop("是");
              },
              child: Container(
                height: 50.w,
                color: Colors.white,
                alignment: Alignment.center,
                child: Text(
                  "是",
                  style: TextStyle(
                      color: const Color(0xFF007AFF), fontSize: 14.sp),
                ),
              ),
            ),
            Container(
              height: 1.w,
              color: const Color(0xFFECECEC),
            ),
            GestureDetector(
              onTap: () {
                Navigator.of(context).pop("否");
              },
              child: Container(
                alignment: Alignment.center,
                height: 50.w,
                color: Colors.white,
                child: Text(
                  "否",
                  style: TextStyle(
                      color: const Color(0xFF007AFF), fontSize: 14.sp),
                ),
              ),
            ),
          ],
        ),
      ),
    );
  }
}
